package leetcode.bfs;

import leetcode.bfs.common.BFSUtils;
import leetcode.tree.common.Node;
import leetcode.tree.common.TreeUtils;

class Solution116 {
    public Node connect(Node root) {
        return BFSUtils.connect(root);
    }
}

public class leetcode116 {
    public static void main(String[] args) {
        Solution116 solution116 = new Solution116();
        Integer[] nums = {1, 2, 3, 4, 5, 6, 7};
        Node root = TreeUtils.generateLeetcodeTreeForNode(nums);
        Node connect = solution116.connect(root);
        System.out.println(TreeUtils.leetcodeStandardOutputForBinaryTreeForNode(connect));
    }
}
